{extend name='table'}

{block name="button"}

<!--{if auth("add")}-->
<button data-modal='{:url("add")}' data-title="{:lang('添加实战')}" class='layui-btn layui-btn-sm layui-btn-primary'>{:lang('添加实战')}</button>
<!--{/if}-->

{/block}

{block name="content"}
<div class="layui-tab layui-tab-card">
    <div class="layui-tab-content">

        <table id="EmployTable" data-url="{:sysuri('getEmployList')}" data-target-search="form.form-search"></table>
    </div>
</div>
<script>

    $(function () {
        $('#EmployTable').layTable({
            even: true, height: 'full',
            cols: [[
                {checkbox: true, fixed: true},
                {field: 'title', title: '{:lang("标题")}', minWidth: 100, align: 'center', templet: '<div>{{d.title||"-"}}</div>'},
                {field: 'details', title: '{:lang("简介")}', minWidth: 100, align: 'center'},
                {field: 'create_at', title: '{:lang("创建时间")}', align: 'center', minWidth: 170, sort: true},
                {toolbar: '#EmployTool', title: '{:lang("操作面板")}', align: 'center', minWidth: 180, fixed: 'right'}
            ]]
        });

    });


</script>



<script type="text/html" id="EmployTool">


    <a class="layui-btn layui-btn-sm layui-btn-danger" onclick="buildEmploy('{{d.title}}', {{d.id}})" >{:lang('确认关联')}</a>

</script>
{/block}
